using FSM.Model;

using System;
using System.Collections.Generic;
using System.Text;

namespace FSM.IBll
{
    public interface ITbFilePredeleteBll
    {
        #region 查询 
        /// <summary> 
        /// 根据键值查询单个信息 
        /// </summary> 
        /// <param name="id">键值</param> 
        /// <returns></returns> 
        tb_file_predelete Get(int? id);

        /// <summary> 
        /// 分页查询批量信息 
        /// </summary> 
        /// <param name="upid">上级键值</param> 
        /// <param name="name">名称</param> 
        /// <param name="del_start_time">删除开始时间</param>
        /// <param name="del_end_time">删除结束时间</param>
        /// <param name="page">页码</param> 
        /// <param name="page_size">每页显示的条数</param> 
        /// <returns></returns> 
        /// <summary> 
        /// 分页查询批量信息 
        /// </summary> 
        /// <param name="upid">上级键值</param> 
        /// <param name="name">名称</param> 
        /// <param name="del_start_time">删除开始时间</param>
        /// <param name="del_end_time">删除结束时间</param>
        /// <param name="isTop">是否只查询顶级删除文件/文件夹（非级联删除的）</param>
        /// <param name="orderName">排序名称</param>
        /// <param name="orderType">排序类型</param>
        /// <param name="page">页码</param> 
        /// <param name="page_size">每页显示的条数</param> 
        /// <returns></returns> 
        Tuple<List<tb_file_predelete>, int> ListPagin(int? upid, string name, DateTime? del_start_time, DateTime? del_end_time, bool isTop, string orderName, int? orderType, int page, int page_size);

        /// <summary> 
        /// 分页查询批量信息 
        /// </summary> 
        /// <param name="upid">上级键值</param> 
        /// <param name="name">名称</param> 
        /// <param name="del_start_time">删除开始时间</param>
        /// <param name="del_end_time">删除结束时间</param>
        /// <param name="delete_id">删除的主ID</param>
        /// <param name="isTop">是否只查询顶级删除文件/文件夹（非级联删除的）</param>
        /// <returns></returns> 
        List<tb_file_predelete> List(int? upid, string name, DateTime? del_start_time, DateTime? del_end_time, int? delete_id, bool isTop);
        #endregion

        #region 提交 
        /// <summary> 
        /// 添加当前列表数据 
        /// </summary> 
        /// <param name="model">实体</param> 
        /// <returns></returns> 
        bool Insert(tb_file_predelete model);

        /// <summary> 
        /// 更新当前列表数据 
        /// </summary> 
        /// <param name="model">实体</param> 
        /// <returns></returns> 
        bool Update(tb_file_predelete model);

        /// <summary> 
        ///  删除当前列表数据 
        /// </summary> 
        /// <param name="id_arr">键值</param> 
        /// <returns></returns> 
        bool Delete(params int?[] id_arr);

        /// <summary>
        /// 删除记录
        /// </summary>
        /// <param name="id">文件/文件夹ID</param>
        /// <param name="callback">callback</param>
        /// <param name="fullPath">文件/文件夹的全目录</param>
        /// <param name="type">1:文件夹 2:文件</param>
        /// <returns></returns>
        bool DeleteFile(int id, Func<string, int, string> callback, string fullPath, int type);

        /// <summary> 
        /// 获得要导出的数据的Excel字节 
        /// </summary> 
        /// <param name="upid">上级键值</param> 
        /// <param name="name">名称</param> 
        /// <returns></returns> 
        //byte[] Export(int? upid, string name); 
        #endregion
    }
}
